import serveUrl from "@/config/serverAddress"; // 接口域名列表
import axios from "@/config/http"; // 导入http中创建的axios实例

const personChange = {
  
  /**
   * @api{property} 添加人员离职信息
   */
  InsertEmployeeLeave(data) {
    return axios.post(`${serveUrl.rs}/ExamineApprove/InsertEmployeeLeave`, data);
  },

  /**
   * @api{property} 添加员工转正信息
   */
  InsertEmployeeRegular(data) {
    return axios.post(`${serveUrl.rs}/ExamineApprove/InsertEmployeeRegular`, data);
  },

  /**
   * @api{property} 添加员工调动信息
   */
  InsertEmployeeTransfer(data) {
    return axios.post(`${serveUrl.rs}/ExamineApprove/InsertEmployeeTransfer`, data);
  },

  /**
   * @api{property} 添加员工调动信息
   */
  GetExamineApproveEmployeeInfo(params) {
    return axios.get(`${serveUrl.rs}/ExamineApprove/GetExamineApproveEmployeeInfo`, { params });
  },

  /**
   * @api{property} 获取入职表单字段
   */
  GetModuleFields() {
    return axios.get(`${serveUrl.rs}/EmployeeEntryColumnSetting/GetModuleFields`);
  },

  /**
   * @api{property} 办理入职
   */
  InsertEmployeeEntry(params, id) {
    return axios.post(`${serveUrl.rs}/ExamineApprove/InsertEmployeeEntry?registerTableId=${id}`, params);
  },
};

export default personChange;
